package com.xgpro.mapper.rolemanage;

import com.xgpro.domain.rolemanage.entity.Department;
import com.xgpro.domain.studycentre.vo.UserDeptVo;
import org.apache.ibatis.annotations.Select;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;

/**
 * @program: xgpro__dev
 * @description: 部门
 * @author: likai
 * @create: 2019-10-13 14:12
 **/
public interface DepartmentMapper extends Mapper<Department> {

    /**
     * 查询部门及部门所属人员信息
     * @param id
     * @return
     */
    List<UserDeptVo> selectDeptUserList(String id);

    @Select("<script>" +
            " select dd_id from t_deptment WHERE pid =#{pid} " +
            "</script>")
    List<String> getSecondDeptId(String pid);
}
